<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
    <title>我的纸条 - {{Session::get('name')}}的个人空间</title>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="author" content="夜读书">
    <meta name="description" content="夜读书中文网">
    <meta name="keywords" content="读书,阅读,小说,文学">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="stylesheet" href="{{ asset('/bootstrap-3.3.5-dist/css/bootstrap.min.css') }}">
    <link rel="stylesheet" href="{{ asset('/style/css/yds.css') }}">
    <link rel="stylesheet" href="{{ asset('/style/css/zhitiao.css') }}">
    <script src="{{ asset('/scripts/jquery/jquery-1.11.3.min.js') }}"></script>
    <script src="{{ asset('/bootstrap-3.3.5-dist/js/bootstrap.min.js') }}"></script>
</head>
<body class="docs">
@include('books.partials.navtop')
@include('books.partials.nav')
<div class="docs-wrapper container zhitiao">
    <div class="title">我的纸条</div>
    @if($zhitiaos != null)
    @foreach($zhitiaos as $zhitiao)
    <div class="item">
        <a class="face" href="{{url('u/'.$zhitiao->friend_id)}}">
            <div class="avatar">                
                @if($zhitiao->receiver_image!="")
                    <img src="{{url($zhitiao->receiver_image)}}">
                @else
                    <img src="{{url('usersface/default/avatar-min.png')}}">
                @endif
            </div>
        </a>
        <div class="content">
            <a class="name" href="{{url('u/'.$zhitiao->friend_id)}}">{{$zhitiao->receiver_name}}</a>
            <div class="description">{!!$zhitiao->content->content!!}</div>
            <div class="extra">
                <span class="delete"><a href="{{url('zhitiao/delallmsg/'.$zhitiao->friend_id)}}" onclick="javascript:return p_del()">删除</a></span>
                <span class="time">{{date('Y-m-d H:i',$zhitiao->send_time)}} <a href="{{url('zhitiao/'.$zhitiao->friend_id)}}">共有 {{$zhitiao->message_count}}条信息, {{$zhitiao->weidu}} 条未读</a></span>
            </div>
        </div>
    </div>
    @endforeach
    @else
        <div class="" style="font-size: 16px;">暂无纸条</div>
    @endif
</div>
<script language="javascript">
    function p_del() {
        var msg= "确定删除本条纸条记录？\n\n";
        if (confirm(msg)==true) {
            return true;
        }
        else
        {
            return false;
        }
    }
</script>

@include('books.partials.footer')
</body>
</html>
